﻿@model SAIM.Models.SocialServiceViewModel
@using MvcFileUploader.HtmlHelper
@using MvcFileUploader.Models
@{
    ViewBag.Title = "Servicio Social";
    ViewBag.Header = "Servicio social";
    //option for inline view only
    var ui = "jquery".Equals(Request.Params["ui"]) ? UploadUI.JQueryUI : UploadUI.Bootstrap;
    var toggleUi = ui == UploadUI.Bootstrap ? "jquery" : "bootstrap";
    var CurrentModelPage = Model != null ? Model.CurrentPage : -1;
    var tipoDeDocumento = "";
    
}

@section css {
    @Styles.Render("~/Content/jquery-steps")
    @Styles.Render("~/Content/datetimepicker")
}

@section Scripts {
    @Scripts.Render("~/bundles/jqueryval")
    @Scripts.Render("~/bundles/jquery-steps")
    @Scripts.Render("~/bundles/datetimepicker")
    @Scripts.Render("~/bundles/pdfMake")
    <script type="text/javascript">
        urlUpdateProgress = '@Url.Action("UpdateProgress", "SocialService")';
        var stepsLabels = {
            cancel: "Cancelar",
            current: "paso actual:",
            pagination: "Paginación",
            finish: "Finalizar",
            next: "Siguiente",
            previous: "Anterior",
            loading: "Cargando ..."
        };
        var currentPage = @CurrentModelPage +1;
    </script>
    <script type="text/javascript" src="@Url.Content("~/Scripts/SocialService/Index.js")"></script>
}

<h2>@ViewBag.Title</h2>

<div class="table table-responsive">
    @using (Html.BeginForm("Manage", "SocialService", FormMethod.Get, new { @class = "form-horizontal social-service-form", role = "form", @id = "social-service-form" }))
    {
        @Html.HiddenFor(m => m.CurrentPage)
        <h3>Datos personales</h3>
        <section>
            <div class="form-group">
                
                @Html.LabelFor(m => m.StudentId, new { @class = "col-sm-3 control-label" })
                <div class="col-sm-9">
                    @Html.TextBoxFor(m => m.StudentId, new { @class = "form-control" })
                    @Html.ValidationMessageFor(m => m.StudentId, "", new { @class = "text-danger" })
                </div>
            </div>
            <div class="form-group">
                @Html.LabelFor(m => m.StudentName, new { @class = "col-sm-3 control-label" })
                <div class="col-sm-9">
                    @Html.TextBoxFor(m => m.StudentName, new { @class = "form-control" })
                    @Html.ValidationMessageFor(m => m.StudentName, "", new { @class = "text-danger" })
                </div>
            </div>
            <div class="form-group">
                @Html.LabelFor(m => m.BirthDate, new { @class = "col-sm-3 control-label" })
                <div class="col-sm-9">
                    <div class='input-group date'>
                        @Html.TextBoxFor(m => m.BirthDate, new { @class = "form-control" })
                        <span class="input-group-addon">
                            <span class="glyphicon glyphicon-calendar"></span>
                        </span>
                    </div>
                    @Html.ValidationMessageFor(m => m.BirthDate, "", new { @class = "text-danger" })
                </div>
            </div>
            <div class="form-group">
                @Html.LabelFor(m => m.Address, new { @class = "col-sm-3 control-label" })
                <div class="col-sm-9">
                    @Html.TextBoxFor(m => m.Address, new { @class = "form-control" })
                    @Html.ValidationMessageFor(m => m.Address, "", new { @class = "text-danger" })
                </div>
            </div>
            <div class="form-group">
                @Html.LabelFor(m => m.StudentPhoneNumber, new { @class = "col-sm-3 control-label" })
                <div class="col-sm-9">
                    @Html.TextBoxFor(m => m.StudentPhoneNumber, new { @class = "form-control" })
                    @Html.ValidationMessageFor(m => m.StudentPhoneNumber, "", new { @class = "text-danger" })
                </div>
            </div>
            <div class="form-group">
                @Html.LabelFor(m => m.CellPhoneNumber, new { @class = "col-sm-3 control-label" })
                <div class="col-sm-9">
                    @Html.TextBoxFor(m => m.CellPhoneNumber, new { @class = "form-control" })
                    @Html.ValidationMessageFor(m => m.CellPhoneNumber, "", new { @class = "text-danger" })
                </div>
            </div>
            <div class="form-group">
                @Html.LabelFor(m => m.Email, new { @class = "col-sm-3 control-label" })
                <div class="col-sm-9">
                    @Html.TextBoxFor(m => m.Email, new { @class = "form-control" })
                    @Html.ValidationMessageFor(m => m.Email, "", new { @class = "text-danger" })
                </div>
            </div>
        </section>

        <h3>Datos: Entidad Académica</h3>
        <section>
            <div class="form-group">
                @Html.LabelFor(m => m.School, new { @class = "col-sm-3 control-label" })
                <div class="col-sm-9">
                    @Html.TextBoxFor(m => m.School, new { @class = "form-control" })
                    @Html.ValidationMessageFor(m => m.School, "", new { @class = "text-danger" })
                </div>
            </div>
            <div class="form-group">
                @Html.LabelFor(m => m.Career, new { @class = "col-sm-3 control-label" })
                <div class="col-sm-9">
                    @Html.TextBoxFor(m => m.Career, new { @class = "form-control" })
                    @Html.ValidationMessageFor(m => m.Career, "", new { @class = "text-danger" })
                </div>
            </div>
            <div class="form-group">
                @Html.LabelFor(m => m.Semester, new { @class = "col-sm-3 control-label" })
                <div class="col-sm-9">
                    @Html.TextBoxFor(m => m.Semester, new { @class = "form-control" })
                    @Html.ValidationMessageFor(m => m.Semester, "", new { @class = "text-danger" })
                </div>
            </div>
            <hr />
            <div class="form-group">
                @Html.LabelFor(m => m.Project, new { @class = "col-sm-3 control-label" })
                <div class="col-sm-9">
                    @Html.TextBoxFor(m => m.Project, new { @class = "form-control" })
                    @Html.ValidationMessageFor(m => m.Project, "", new { @class = "text-danger" })
                </div>
            </div>
            <div class="form-group">
                @Html.LabelFor(m => m.ResponsiblePerson, new { @class = "col-sm-3 control-label" })
                <div class="col-sm-9">
                    @Html.TextBoxFor(m => m.ResponsiblePerson, new { @class = "form-control" })
                    @Html.ValidationMessageFor(m => m.ResponsiblePerson, "", new { @class = "text-danger" })
                </div>
            </div>
            <div class="form-group">
                @Html.LabelFor(m => m.ActivitiesLaboratories, new { @class = "col-sm-3 control-label" })
                <div class="col-sm-9">
                    @Html.TextAreaFor(m => m.ActivitiesLaboratories, new { @class = "form-control saim-text-area-static" })
                    @Html.ValidationMessageFor(m => m.ActivitiesLaboratories, "", new { @class = "text-danger" })
                </div>
            </div>
        </section>

        <h3>Actividades y horario</h3>
        <section>
            <div class="form-group">
                @Html.LabelFor(m => m.ActivitiesToDo, new { @class = "col-sm-3 control-label" })
                <div class="col-sm-9">
                    @Html.TextAreaFor(m => m.ActivitiesToDo, new { @class = "form-control saim-text-area-static" })
                    @Html.ValidationMessageFor(m => m.ActivitiesToDo, "", new { @class = "text-danger" })
                </div>
            </div>
            <div class="form-group">
                @Html.LabelFor(m => m.InitialDate, new { @class = "col-sm-3 control-label" })
                <div class="col-sm-9">
                    <div class='input-group date'>
                        @Html.TextBoxFor(m => m.InitialDate, new { @class = "form-control" })
                        <span class="input-group-addon">
                            <span class="glyphicon glyphicon-calendar"></span>
                        </span>
                    </div>
                    @Html.ValidationMessageFor(m => m.InitialDate, "", new { @class = "text-danger" })
                </div>
            </div>
            <div class="form-group">
                @Html.LabelFor(m => m.EndDate, new { @class = "col-sm-3 control-label" })
                <div class="col-sm-9">
                    <div class='input-group date'>
                        @Html.TextBoxFor(m => m.EndDate, new { @class = "form-control" })
                        <span class="input-group-addon">
                            <span class="glyphicon glyphicon-calendar"></span>
                        </span>
                    </div>
                    @Html.ValidationMessageFor(m => m.EndDate, "", new { @class = "text-danger" })
                </div>
            </div>

            <div class="form-group">
                @Html.LabelFor(m => m.CheckInTime1, new { @class = "col-sm-3 control-label" })
                <div class="col-sm-9">
                    @Html.TextAreaFor(m => m.CheckInTime1, new { @class = "form-control" })
                    @Html.ValidationMessageFor(m => m.CheckInTime1, "", new { @class = "text-danger" })
                </div>
            </div>
            <!--
            <div class="form-group">
                @Html.LabelFor(m => m.DepartureTime1, new { @class = "col-sm-3 control-label" })
                <div class="col-sm-9">
                    <div class='input-group date'>
                        @Html.TextBoxFor(m => m.DepartureTime1, new { @class = "form-control" })
                        <span class="input-group-addon">
                            <span class="glyphicon glyphicon-time"></span>
                        </span>
                    </div>
                    @Html.ValidationMessageFor(m => m.DepartureTime1, "", new { @class = "text-danger" })
                </div>
            </div>
            <div class="form-group">
                <label class="col-sm-3 control-label">Horario segunda parte</label>
            </div>
            <div class="form-group">
                @Html.LabelFor(m => m.CheckInTime2, new { @class = "col-sm-3 control-label" })
                <div class="col-sm-9">
                    <div class='input-group date'>
                        @Html.TextBoxFor(m => m.CheckInTime2, new { @class = "form-control" })
                        <span class="input-group-addon">
                            <span class="glyphicon glyphicon-time"></span>
                        </span>
                    </div>
                    @Html.ValidationMessageFor(m => m.CheckInTime2, "", new { @class = "text-danger" })
                </div>
            </div>
            <div class="form-group">
                @Html.LabelFor(m => m.DepartureTime2, new { @class = "col-sm-3 control-label" })
                <div class="col-sm-9">
                    <div class='input-group date'>
                        @Html.TextBoxFor(m => m.DepartureTime2, new { @class = "form-control" })
                        <span class="input-group-addon">
                            <span class="glyphicon glyphicon-time"></span>
                        </span>
                    </div>
                    @Html.ValidationMessageFor(m => m.DepartureTime2, "", new { @class = "text-danger" })
                </div>
            </div>
                -->
        </section>

        <h3>Modalidad de la estancía</h3>
        <section>
            <div class="form-group">
                @Html.LabelFor(m => m.StayModality, new { @class = "col-sm-3 control-label" })
                <div class="col-sm-9">
                    @Html.RadioButtonFor(m => m.StayModality, "Alumno", new { @id = "radio-button-Alumno" })@Html.Label("Alumno")
                    <br />
                   

                           
                     
                    <div class="radio-inline">
                        @Html.RadioButtonFor(m => m.StayModalityGrade, "Doctorado", new { @class = "radio-button-staymodalitygrade-alumno", @id = "radio-button-staymodalitygrade-alumno-doctorado" }) @Html.Label("Doctorado", new { @class = "radio-button-staymodalitygrade-alumno" })
                    </div>
                    <div class="radio-inline">
                        @Html.RadioButtonFor(m => m.StayModalityGrade, "Licenciatura", new { @class = "radio-button-staymodalitygrade-alumno", @id = "radio-button-staymodalitygrade-alumno-licenciatura" }) @Html.Label("Licenciatura", new { @class = "radio-button-staymodalitygrade-alumno" })
                    </div>
                    <div class="radio-inline">
                        @Html.RadioButtonFor(m => m.StayModalityGrade, "Maestría", new { @class = "radio-button-staymodalitygrade-alumno", @id = "radio-button-staymodalitygrade-alumno-maestria" }) @Html.Label("Maestría", new { @class = "radio-button-staymodalitygrade-alumno" })
                    </div>
                    <br />
                    <br />
                    <div class="radio-inline">
                        @Html.RadioButtonFor(m => m.StayModalityType, "Tesistas", new { @class = "radio-button-staymodalitytype-alumno", @id = "radio-button-staymodalitytype-alumno-tesistas" }) @Html.Label("Tesistas", new { @class = "radio-button-staymodalitytype-alumno" })
                    </div>
                    <div class="radio-inline">
                        @Html.RadioButtonFor(m => m.StayModalityType, "Servicio social", new { @class = "radio-button-staymodalitytype-alumno", @id = "radio-button-staymodalitytype-alumno-ss" }) @Html.Label("Servicio Social", new { @class = "radio-button-staymodalitytype-alumno" })
                    </div>
                    <div class="radio-inline">
                        @Html.RadioButtonFor(m => m.StayModalityType, "Practicas profesionales", new { @class = "radio-button-staymodalitytype-alumno", @id = "radio-button-staymodalitytype-alumno-pp" }) @Html.Label("Practicas Profesionales", new { @class = "radio-button-staymodalitytype-alumno" })
                    </div>
                    <div class="radio-inline">
                        @Html.RadioButtonFor(m => m.StayModalityType, "Intercambio/Movilidad", new { @class = "radio-button-staymodalitytype-alumno", @id = "radio-button-staymodalitytype-alumno-movilidad" }) @Html.Label("Intercambio/Movilidad", new { @class = "radio-button-staymodalitytype-alumno" })
                    </div>
                   

                    <br />
                    <br />
                    @Html.RadioButtonFor(m => m.StayModality, "Profesor", new { @id = "radio-button-Profesor" })@Html.Label("Profesor")
                    <br />
                    @Html.HiddenFor(m => m.StayModalityType)
                  


                      
                      
                    <div class="radio-inline">
                        @Html.RadioButtonFor(m => m.StayModalityGrade, "PosDoctorado", new { @class = "radio-button-staymodalitygrade-profesor", @id = "radio-button-staymodalitygrade-profesor-posdoctorado" })@Html.Label("PosDoctorado", new { @class = "radio-button-staymodalitygrade-profesor" })
                    </div>
                    <div class="radio-inline">
                        @Html.RadioButtonFor(m => m.StayModalityGrade, "Visitantes", new { @class = "radio-button-staymodalitygrade-profesor", @id = "radio-button-staymodalitygrade-profesor-visitantes" })@Html.Label("Visitantes", new { @class = "radio-button-staymodalitygrade-profesor" })
                    </div>
                    <div class="radio-inline">
                        @Html.RadioButtonFor(m => m.StayModalityGrade, "Tecnico academico por proyecto", new { @class = "radio-button-staymodalitygrade-profesor", @id = "radio-button-staymodalitygrade-profesor-tap" })@Html.Label("Tecnico academico por proyecto", new { @class = "radio-button-staymodalitygrade-profesor" })
                    </div>

                      

                    @Html.HiddenFor(m => m.StayModality, new { @class = "form-control" })
                    @Html.ValidationMessageFor(m => m.StayModality, "", new { @class = "text-danger" })

                </div>
                <br />
              
                        <div class="form-group">
                            @Html.Label("Otros", new { @class = "col-sm-3 control-label StayModalityTypeOtros" })
                            <div class="col-sm-9">
                                @Html.TextBoxFor(m => m.StayModalityGrade, new { @class = "StayModalityTypeOtros form-control" })
                                @Html.ValidationMessageFor(m => m.StayModalityGrade, "", new { @class = "text-danger" })
                            </div>
                        </div>
                   
                       
                
                <div class="form-group">
                    @Html.HiddenFor(m => m.StayModalityGrade, new { @class = "col-sm-3 control-label" })
                    <div class="col-sm-9">
                        @Html.HiddenFor(m => m.StayModalityGrade, new { @class = "form-control" })
                        @Html.ValidationMessageFor(m => m.StayModalityGrade, "", new { @class = "text-danger" })
                    </div>
                </div>

                <div class="form-group">
                    @Html.LabelFor(m => m.ResponsibleSocialService, new { @class = "col-sm-3 control-label" })
                    <div class="col-sm-9">
                        @Html.TextBoxFor(m => m.ResponsibleSocialService, new { @class = "form-control" })
                        @Html.ValidationMessageFor(m => m.ResponsibleSocialService, "", new { @class = "text-danger" })
                    </div>
                </div>
                <div class="form-group">
                    <div class="col-sm-9 col-sm-offset-3">
                        <button id="generar-carta-de-aceptacion" type="button" class="btn btn-primary" aria-label="Left Align">
                            <span class="glyphicon glyphicon-file" aria-hidden="true"></span> @SAIM.Resources.Site.Generate
                        </button>
                    </div>
                </div>

            </div>
        </section>

        <h3>Seguro médico y estado de salud (1)</h3>
        <section>
            <div class="form-group">
                @Html.LabelFor(m => m.InsuranceType, new { @class = "col-sm-3 control-label" })
                <div class="col-sm-9">
                    @Html.TextBoxFor(m => m.InsuranceType, new { @class = "form-control" })
                    
                </div>
            </div>
            <div class="form-group">
                @Html.LabelFor(m => m.InsuranceNumber, new { @class = "col-sm-3 control-label" })
                <div class="col-sm-9">
                    @Html.TextBoxFor(m => m.InsuranceNumber, new { @class = "form-control" })
                    @Html.ValidationMessageFor(m => m.InsuranceNumber, "", new { @class = "text-danger" })
                </div>
            </div>
            <div class="form-group">
                @Html.LabelFor(m => m.BloodType, new { @class = "col-sm-3 control-label" })
                <div class="col-sm-9">
                    @Html.TextBoxFor(m => m.BloodType, new { @class = "form-control" })
                    @Html.ValidationMessageFor(m => m.BloodType, "", new { @class = "text-danger" })
                </div>
            </div>
            <div class="form-group">
                @Html.LabelFor(m => m.Asthma, new { @class = "col-sm-3 control-label" })
                <div class="col-sm-9">
                    @Html.TextBoxFor(m => m.Asthma, new { @class = "form-control" })
                    @Html.ValidationMessageFor(m => m.Asthma, "", new { @class = "text-danger" })
                </div>
            </div>
            <div class="form-group">
                @Html.LabelFor(m => m.Diabetes, new { @class = "col-sm-3 control-label" })
                <div class="col-sm-9">
                    @Html.TextBoxFor(m => m.Diabetes, new { @class = "form-control" })
                    @Html.ValidationMessageFor(m => m.Diabetes, "", new { @class = "text-danger" })
                </div>
            </div>
            <div class="form-group">
                @Html.LabelFor(m => m.Headache, new { @class = "col-sm-3 control-label" })
                <div class="col-sm-9">
                    @Html.TextBoxFor(m => m.Headache, new { @class = "form-control" })
                    @Html.ValidationMessageFor(m => m.Headache, "", new { @class = "text-danger" })
                </div>
            </div>
            <div class="form-group">
                @Html.LabelFor(m => m.Epilepsy, new { @class = "col-sm-3 control-label" })
                <div class="col-sm-9">
                    @Html.TextBoxFor(m => m.Epilepsy, new { @class = "form-control" })
                    @Html.ValidationMessageFor(m => m.Epilepsy, "", new { @class = "text-danger" })
                </div>
            </div>
            <div class="form-group">
                @Html.LabelFor(m => m.DigestiveProblems, new { @class = "col-sm-3 control-label" })
                <div class="col-sm-9">
                    @Html.TextBoxFor(m => m.DigestiveProblems, new { @class = "form-control" })
                    @Html.ValidationMessageFor(m => m.DigestiveProblems, "", new { @class = "text-danger" })
                </div>
            </div>
            <div class="form-group">
                @Html.LabelFor(m => m.CardiacAfections, new { @class = "col-sm-3 control-label" })
                <div class="col-sm-9">
                    @Html.TextBoxFor(m => m.CardiacAfections, new { @class = "form-control" })
                    @Html.ValidationMessageFor(m => m.CardiacAfections, "", new { @class = "text-danger" })
                </div>
            </div>
        </section>

        <h3>Seguro médico y estado de salud (2)</h3>
        <section>
            <div class="form-group">
                @Html.LabelFor(m => m.VisionAffections, new { @class = "col-sm-3 control-label" })
                <div class="col-sm-9">
                    @Html.TextBoxFor(m => m.VisionAffections, new { @class = "form-control" })
                    @Html.ValidationMessageFor(m => m.VisionAffections, "", new { @class = "text-danger" })
                </div>
            </div>
            <div class="form-group">
                @Html.LabelFor(m => m.SkinAffections, new { @class = "col-sm-3 control-label" })
                <div class="col-sm-9">
                    @Html.TextBoxFor(m => m.SkinAffections, new { @class = "form-control" })
                    @Html.ValidationMessageFor(m => m.SkinAffections, "", new { @class = "text-danger" })
                </div>
            </div>
            <div class="form-group">
                @Html.LabelFor(m => m.RespiratoryProblems, new { @class = "col-sm-3 control-label" })
                <div class="col-sm-9">
                    @Html.TextBoxFor(m => m.RespiratoryProblems, new { @class = "form-control" })
                    @Html.ValidationMessageFor(m => m.RespiratoryProblems, "", new { @class = "text-danger" })
                </div>
            </div>
            <div class="form-group">
                @Html.LabelFor(m => m.Disability, new { @class = "col-sm-3 control-label" })
                <div class="col-sm-9">
                    @Html.TextBoxFor(m => m.Disability, new { @class = "form-control" })
                    @Html.ValidationMessageFor(m => m.Disability, "", new { @class = "text-danger" })
                </div>
            </div>
            <div class="form-group">
                @Html.LabelFor(m => m.Allergies, new { @class = "col-sm-3 control-label" })
                <div class="col-sm-9">
                    @Html.TextBoxFor(m => m.Allergies, new { @class = "form-control" })
                    @Html.ValidationMessageFor(m => m.Allergies, "", new { @class = "text-danger" })
                </div>
            </div>
            <div class="form-group">
                @Html.LabelFor(m => m.Hypertension, new { @class = "col-sm-3 control-label" })
                <div class="col-sm-9">
                    @Html.TextBoxFor(m => m.Hypertension, new { @class = "form-control" })
                    @Html.ValidationMessageFor(m => m.Hypertension, "", new { @class = "text-danger" })
                </div>
            </div>
            <div class="form-group">
                @Html.LabelFor(m => m.Specials, new { @class = "col-sm-3 control-label" })
                <div class="col-sm-9">
                    @Html.TextBoxFor(m => m.Specials, new { @class = "form-control" })
                    @Html.ValidationMessageFor(m => m.Specials, "", new { @class = "text-danger" })
                </div>
            </div>
            <div class="form-group">
                @Html.LabelFor(m => m.LastTetanusVaccine, new { @class = "col-sm-3 control-label" })
                <div class="col-sm-9">
                    @Html.TextBoxFor(m => m.LastTetanusVaccine, new { @class = "form-control" })
                    @Html.ValidationMessageFor(m => m.LastTetanusVaccine, "", new { @class = "text-danger" })
                </div>
            </div>
            <div class="form-group">
                @Html.LabelFor(m => m.SpecialMedicationText, new { @class = "col-sm-3 control-label" })
                <div class="col-sm-9">
                    @Html.TextAreaFor(m => m.SpecialMedicationText, new { @class = "form-control saim-text-area-static" })
                    @Html.ValidationMessageFor(m => m.SpecialMedicationText, "", new { @class = "text-danger" })
                </div>
            </div>
        </section>

        <h3>Contacto en caso de emergencia</h3>
        <section>
            <div class="form-group">
                @Html.LabelFor(m => m.PrimaryContactRelationship, new { @class = "col-sm-3 control-label" })
                <div class="col-sm-9">
                    @Html.TextBoxFor(m => m.PrimaryContactRelationship, new { @class = "form-control" })
                    @Html.ValidationMessageFor(m => m.PrimaryContactRelationship, "", new { @class = "text-danger" })
                </div>
            </div>
            <div class="form-group">
                @Html.LabelFor(m => m.PrimaryContactName, new { @class = "col-sm-3 control-label" })
                <div class="col-sm-9">
                    @Html.TextBoxFor(m => m.PrimaryContactName, new { @class = "form-control" })
                    @Html.ValidationMessageFor(m => m.PrimaryContactName, "", new { @class = "text-danger" })
                </div>
            </div>
            <div class="form-group">
                @Html.LabelFor(m => m.PrimaryContactAddress, new { @class = "col-sm-3 control-label" })
                <div class="col-sm-9">
                    @Html.TextBoxFor(m => m.PrimaryContactAddress, new { @class = "form-control" })
                    @Html.ValidationMessageFor(m => m.PrimaryContactAddress, "", new { @class = "text-danger" })
                </div>
            </div>
            <div class="form-group">
                @Html.LabelFor(m => m.PrimaryContactPhone, new { @class = "col-sm-3 control-label" })
                <div class="col-sm-9">
                    @Html.TextBoxFor(m => m.PrimaryContactPhone, new { @class = "form-control" })
                    @Html.ValidationMessageFor(m => m.PrimaryContactPhone, "", new { @class = "text-danger" })
                </div>
            </div>
            <div class="form-group">
                @Html.LabelFor(m => m.PrimaryContactCellphone, new { @class = "col-sm-3 control-label" })
                <div class="col-sm-9">
                    @Html.TextBoxFor(m => m.PrimaryContactCellphone, new { @class = "form-control" })
                    @Html.ValidationMessageFor(m => m.PrimaryContactCellphone, "", new { @class = "text-danger" })
                </div>
            </div>
            <br />


            <div class="form-group">
                @Html.LabelFor(m => m.SecundaryContactRelationship, new { @class = "col-sm-3 control-label" })
                <div class="col-sm-9">
                    @Html.TextBoxFor(m => m.SecundaryContactRelationship, new { @class = "form-control" })
                    @Html.ValidationMessageFor(m => m.SecundaryContactRelationship, "", new { @class = "text-danger" })
                </div>
            </div>
            <div class="form-group">
                @Html.LabelFor(m => m.SecundaryContactName, new { @class = "col-sm-3 control-label" })
                <div class="col-sm-9">
                    @Html.TextBoxFor(m => m.SecundaryContactName, new { @class = "form-control" })
                    @Html.ValidationMessageFor(m => m.SecundaryContactName, "", new { @class = "text-danger" })
                </div>
            </div>
            <div class="form-group">
                @Html.LabelFor(m => m.SecundaryContactAddress, new { @class = "col-sm-3 control-label" })
                <div class="col-sm-9">
                    @Html.TextBoxFor(m => m.SecundaryContactAddress, new { @class = "form-control" })
                    @Html.ValidationMessageFor(m => m.SecundaryContactAddress, "", new { @class = "text-danger" })
                </div>
            </div>
            <div class="form-group">
                @Html.LabelFor(m => m.SecundaryContactPhone, new { @class = "col-sm-3 control-label" })
                <div class="col-sm-9">
                    @Html.TextBoxFor(m => m.SecundaryContactPhone, new { @class = "form-control" })
                    @Html.ValidationMessageFor(m => m.SecundaryContactPhone, "", new { @class = "text-danger" })
                </div>
            </div>
            <div class="form-group">
                @Html.LabelFor(m => m.SecundaryContactCellphone, new { @class = "col-sm-3 control-label" })
                <div class="col-sm-9">
                    @Html.TextBoxFor(m => m.SecundaryContactCellphone, new { @class = "form-control" })
                    @Html.ValidationMessageFor(m => m.SecundaryContactCellphone, "", new { @class = "text-danger" })
                </div>
            </div>
        </section>

        <h3>Captura y generación de formatos</h3>
    <section>

        <div class="panel panel-info">
            <div class="panel-heading">
                Captura de documentos
            </div>
            <div class="panel-body">
                <table id="social-service-documents" class="table table-condensed table-hover">
                    <thead>
                        <tr>
                            <th data-column-id="id">Opciones</th>
                            <th data-column-id="sender">Descripción</th>
                            <th data-column-id="received">Nombre del archivo</th>
                        </tr>
                    </thead>
                    <tbody>
                        <tr>
                            <td>
                                <button id="CartaDeAceptacion" type="button" class="btn btn-primary btn-sm" aria-label="Left Align" data-type="CartaAceptacion" title="Adjuntar archivo">
                                    <span class="fontelloicon icon-upload-cloud-4" aria-hidden="true"></span>
                                </button>
                                @if(Model!=null)
                                {
                                   
                                    
                                <a href="@Url.Action("GetAttachedFile", "SocialService")/@Model.StudentId?typeDocument=CartaAceptacion" title="Descargar archivo" role="button" class="btn btn-primary">

                                    <span class="fontelloicon icon-download-5" aria-hidden="true"></span>
                                </a>
                                }
                            </td>
                            <td>Carta de aceptación sellada</td>
                            <td> Carta de aceptación sellada.pdf</td>
                        </tr>
                        <tr>
                            <td>
                                <button id="CartaDeAsignacion" type="button" class="btn btn-primary btn-sm " aria-label="Left Align" data-type="CartaAsignacion" title="Adjuntar archivo">
                                    <span class="fontelloicon icon-upload-cloud-4" aria-hidden="true"></span>
                                </button>
                                @if(Model!=null)
                                {
                                <a href="@Url.Action("GetAttachedFile", "SocialService")/@Model.StudentId?typeDocument=CartaAsignacion" title="Descargar archivo" role="button" class="btn btn-primary">

                                    <span class="fontelloicon icon-download-5" aria-hidden="true"></span>
                                </a>
                                }
                            </td>
                            <td>Carta de asignación</td>
                            <td>Carta de asignacion.pdf</td>
                        </tr>
                        <tr>
                            <td>
                                <button id="SeguroMedico" type="button" class="btn btn-primary btn-sm" aria-label="Left Align" data-type="CartaSeguroMedico" title="Adjuntar archivo">
                                    <span class="fontelloicon icon-upload-cloud-4" aria-hidden="true"></span>
                                </button>
                                @if(Model!=null)
                                {
                                <a href="@Url.Action("GetAttachedFile", "SocialService")/@Model.StudentId?typeDocument=SeguroMedico" title="Descargar archivo" role="button" class="btn btn-primary">

                                    <span class="fontelloicon icon-download-5" aria-hidden="true"></span>
                                </a>
                                }
                            </td>
                            <td>Seguro médico</td>
                            <td>Seguro médico.pdf</td>
                        </tr>
                    </tbody>
                </table>
            </div>
        </div>
        <div class="panel panel-info">
            <div class="panel-heading">
                Generación de formatos
            </div>
            <div class="panel-body">
                <table id="social-service-documents" class="table table-condensed table-hover">
                    <thead>
                        <tr>
                            <th data-column-id="id">Opciones</th>
                            <th data-column-id="sender">Descripción</th>
                            <th data-column-id="received">Nombre del archivo</th>
                        </tr>
                    </thead>
                    <tbody>
                        <tr>
                            <td>
                                <button id="generar-carta" type="button" class="btn btn-primary btn-sm" aria-label="Left Align" title="Generar formato">
                                    <span class="glyphicon glyphicon-file" aria-hidden="true"></span>
                                </button>
                            </td>
                            <td>Carta de aceptación</td>
                            <td>CartaAceptacion.pdf</td>
                        </tr>
                        <tr>
                            <td>
                                <button id="generar-hoja-de-registro" type="button" class="btn btn-primary btn-sm" aria-label="Left Align" title="Generar formato">
                                    <span class="glyphicon glyphicon-file" aria-hidden="true"></span>
                                </button>

                                <input style="display: none; visibility: hidden;" id="inputFileToLoad" type="file" />
                                <div id="imgTest" style="display: none;"></div>
                                <button type="button" onclick="document.getElementById('inputFileToLoad').click();" class="btn btn-info btn-sm">Subir Foto</button>

                            </td>
                            <td>Hoja de registro</td>
                            <td>HojaRegistro.pdf</td>
                        </tr>
                        <tr>
                            <td>
                                <button id="generar-ficha-medica" type="button" class="btn btn-primary btn-sm" aria-label="Left Align" title="Generar formato">
                                    <span class="glyphicon glyphicon-file" aria-hidden="true"></span>
                                </button>
                            </td>
                            <td>Ficha médica</td>
                            <td>FichaMedica.pdf</td>
                        </tr>
                    </tbody>
                </table>
            </div>
        </div>
    </section>


    }
</div>
@if(Model!=null)
{ 
<div id="attachmentsModal" class="modal fade" role="dialog">
    <div class="modal-dialog modal-lg">
        <div class="modal-content">
            <div class="modal-header">
                <button type="button" class="close" data-dismiss="modal">&times;</button>
                <h4 class="modal-title">Adjuntar archivo</h4>
            </div>
            <div class="modal-body">
                <p class="help-block">Formatos permitidos: jpg, jpeg, png, pdf</p>
                @(
                            Html.MvcFileUpload()
                            .UploadAt(Url.Action("UploadFile"))
                            .UIStyle(ui)
                            .WithFileTypes(@"/(\.|\/)(gif|jpe?g|tiff|png|pdf|docx?|xlsx?|xml|txt)$/i")
                            .WithMaxFileSize(10000000)
                            .AddFormField("entityId", Model.StudentId.ToString())
                            .AddFormField("StudentName", Model.StudentName.ToString())
                            .AddFormField("tipoDeDocumento",tipoDeDocumento)                            
                            .RenderInline("_MvcFileupload")
                )
            </div>
        </div>
    </div>
</div>
}